package com.wuhao.shootclient.bean;

import java.util.ArrayList;
import java.util.List;

/**
 * Create by hao on 2019-11-24
 */
public class ShootFireVo {

    /**
     * id : 5  弹孔
     * score : 10.0  环数
     * orientation : 偏上
     * angel : 358 度数
     * x : 322
     * y : 346
     * position_number : 1 射击位
     * status : 0
     * all_points : null
     * create_at : 2019年11月24日 20时25分03秒
     */

    private float score;
    private String orientation;
    private int angel;
    public int x;
    public int y;
    private String image;
    private boolean enable_circle_float;
    private float allScore;

    private String target_type;

    public float getAllScore() {
        return allScore;
    }

    public void setAllScore(float allScore) {
        this.allScore = allScore;
    }

    public boolean isEnable_circle_float() {
        return enable_circle_float;
    }

    public void setEnable_circle_float(boolean enable_circle_float) {
        this.enable_circle_float = enable_circle_float;
    }

    public float getScore() {
        return score;
    }

    public void setScore(float score) {
        this.score = score;
    }

    public String getOrientation() {
        return orientation;
    }

    public void setOrientation(String orientation) {
        this.orientation = orientation;
    }

    public int getAngel() {
        return angel;
    }

    public void setAngel(int angel) {
        this.angel = angel;
    }

    public int getX() {
        return x;
    }

    public void setX(int x) {
        this.x = x;
    }

    public int getY() {
        return y;
    }

    public void setY(int y) {
        this.y = y;
    }

    public String getImage() {
        return image;
    }

    public void setImage(String image) {
        this.image = image;
    }

    public ShootFireVo(int x, int y) {
        this.x = x;
        this.y = y;
    }

    public ShootFireVo() {
        this.x = x;
        this.y = y;
    }

    public ShootFireVo(float score, String orientation, int angel, int x, int y, String image, boolean enable_circle_float, float allScore,String target_type) {
        this.score = score;
        this.orientation = orientation;
        this.angel = angel;
        this.x = x;
        this.y = y;
        this.image = image;
        this.enable_circle_float = enable_circle_float;
        this.allScore = allScore;
        this.target_type = target_type;
    }

    public ShootFireVo(float score, String orientation, int angel, int x, int y,float allScore) {
        this.score = score;
        this.orientation = orientation;
        this.angel = angel;
        this.x = x;
        this.y = y;
        this.allScore = allScore;

    }

    public ShootFireVo(float score, String orientation, float allScore) {
        this.score = score;
        this.orientation = orientation;
        this.allScore = allScore;
    }
    //暂不使用
//    public static ShootRegisterVo.RecordsBean from(int number, RegistertestVo.RecordsBean.ResultsBean.AllPointsBean record, Integer clientW, Integer clientH, RegistertestVo.RecordsBean.ResultsBean.PaperBean paper, int bullet_num_today) {
//
//        ShootRegisterVo.RecordsBean vo = new ShootRegisterVo.RecordsBean();
//        ArrayList<ShootFireVo> pointIS = new ArrayList<ShootFireVo>();
//        pointIS.add(record.getCenter(clientW, clientH, paper));
//        vo.setAll_points(pointIS);
//
//        return vo;
//    }


    public static ShootRegisterVo.RecordsBean from(Integer cut_width,Integer cut_height,List<ResultsBean.AllPointsBean> allRecord, Integer clientW, Integer clientH, ResultsBean.AllPointsBean paper,
                                                   double tenWidthRadiuProportion , double tenHeightRadiuProportion,String target_type) {
        ShootRegisterVo.RecordsBean vo = new ShootRegisterVo.RecordsBean();
        ArrayList<ShootFireVo> pointIS = new ArrayList<>();
        for (ResultsBean.AllPointsBean shootRecord : allRecord) {
            pointIS.add(shootRecord.getCenter(cut_width,cut_height,clientW, clientH, paper, tenWidthRadiuProportion , tenHeightRadiuProportion,target_type));
        }
        vo.setAll_points(pointIS);
        return vo;
    }

    public String getTarget_type() {
        return target_type;
    }

    public void setTarget_type(String target_type) {
        this.target_type = target_type;
    }
}
